package com.dfbz.bigdata.modules.system.doman;



import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 
 * @TableName tb_user_brand
 */
@TableName(value ="tb_user_brand")
@Data
public class UserBrand implements Serializable {
    /**
     * 店铺id
     */
    @TableId
    private Long brandsId;

    /**
     * 创建人
     */
    private Long userId;


    /**
     * 店铺名
     */
    private String brandsName;

    /**
     * 手机号
     */
    private Integer brandsPhone;

    /**
     * 邮箱
     */
    private String brandsEmail;

    /**
     * 店铺头像
     */
    private String brandsIcon;

    /**
     * 店铺描述
     */
    private String brandsText;

    /**
     * 上传认证信息
     */
    private String brandsCertify;

    /**
     * 密码
     */
    private String brandsPwd;

    /**
     * 等级标签
     */
    private String brandsLabel;

    /**
     * 创建时间
     */
    @JsonFormat(shape=JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date createTime;

    /**
     * 更新时间
     */
    @JsonFormat(shape=JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date updateTime;

    /**
     * 创建人
     */
    private Long createUser;

    /**
     * 修改人
     */
    private Long updateUser;

    /**
     * 是否删除
     */
    @TableLogic(value = "0",delval = "1")
    private Integer isDeleted;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        UserBrand other = (UserBrand) that;
        return (this.getBrandsId() == null ? other.getBrandsId() == null : this.getBrandsId().equals(other.getBrandsId()))
            && (this.getBrandsName() == null ? other.getBrandsName() == null : this.getBrandsName().equals(other.getBrandsName()))
            && (this.getBrandsPhone() == null ? other.getBrandsPhone() == null : this.getBrandsPhone().equals(other.getBrandsPhone()))
            && (this.getBrandsEmail() == null ? other.getBrandsEmail() == null : this.getBrandsEmail().equals(other.getBrandsEmail()))
            && (this.getBrandsIcon() == null ? other.getBrandsIcon() == null : this.getBrandsIcon().equals(other.getBrandsIcon()))
            && (this.getBrandsText() == null ? other.getBrandsText() == null : this.getBrandsText().equals(other.getBrandsText()))
            && (this.getBrandsCertify() == null ? other.getBrandsCertify() == null : this.getBrandsCertify().equals(other.getBrandsCertify()))
            && (this.getBrandsPwd() == null ? other.getBrandsPwd() == null : this.getBrandsPwd().equals(other.getBrandsPwd()))
            && (this.getBrandsLabel() == null ? other.getBrandsLabel() == null : this.getBrandsLabel().equals(other.getBrandsLabel()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getCreateUser() == null ? other.getCreateUser() == null : this.getCreateUser().equals(other.getCreateUser()))
            && (this.getUpdateUser() == null ? other.getUpdateUser() == null : this.getUpdateUser().equals(other.getUpdateUser()))
            && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getBrandsId() == null) ? 0 : getBrandsId().hashCode());
        result = prime * result + ((getBrandsName() == null) ? 0 : getBrandsName().hashCode());
        result = prime * result + ((getBrandsPhone() == null) ? 0 : getBrandsPhone().hashCode());
        result = prime * result + ((getBrandsEmail() == null) ? 0 : getBrandsEmail().hashCode());
        result = prime * result + ((getBrandsIcon() == null) ? 0 : getBrandsIcon().hashCode());
        result = prime * result + ((getBrandsText() == null) ? 0 : getBrandsText().hashCode());
        result = prime * result + ((getBrandsCertify() == null) ? 0 : getBrandsCertify().hashCode());
        result = prime * result + ((getBrandsPwd() == null) ? 0 : getBrandsPwd().hashCode());
        result = prime * result + ((getBrandsLabel() == null) ? 0 : getBrandsLabel().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getCreateUser() == null) ? 0 : getCreateUser().hashCode());
        result = prime * result + ((getUpdateUser() == null) ? 0 : getUpdateUser().hashCode());
        result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", brandsId=").append(brandsId);
        sb.append(", brandsName=").append(brandsName);
        sb.append(", brandsPhone=").append(brandsPhone);
        sb.append(", brandsEmail=").append(brandsEmail);
        sb.append(", brandsIcon=").append(brandsIcon);
        sb.append(", brandsText=").append(brandsText);
        sb.append(", brandsCertify=").append(brandsCertify);
        sb.append(", brandsPwd=").append(brandsPwd);
        sb.append(", brandsLabel=").append(brandsLabel);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", createUser=").append(createUser);
        sb.append(", updateUser=").append(updateUser);
        sb.append(", isDeleted=").append(isDeleted);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}